<?xml version="1.0" encoding="ISO-8859-15"?>
<!-- Copyright (c) 2006 DAKOSY AG (http://www.dakosy.de) -->
<!-- XSD-Version 2.0 / 14-Dec-2006 -->
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
	<xsd:complexType name="BusinessUnitDef">
		<xsd:annotation>
			<xsd:documentation>Location of a branch office.</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="Code" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>UN/Locode; e.g. the location of the user's branch office.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:minLength value="1"/>
						<xsd:maxLength value="5"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Name" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>If there is no UN/LoCode available for this place, alternatively the name can be set.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="CommunicationDef">
		<xsd:annotation>
			<xsd:documentation>Communication data, e. g. the message's creation time or sender, recipient</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="Participants">
				<xsd:annotation>
					<xsd:documentation>Up to 11 entries can be sent:</xsd:documentation>
					<xsd:documentation>SENDER - mandatory with DAKOSY-code</xsd:documentation>
					<xsd:documentation>RECIPIENT - mandatory with DAKOSY-Code. Maximum of nine entries is possible.</xsd:documentation>
					<xsd:documentation>EDI_PROVIDER</xsd:documentation>
				</xsd:annotation>
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="Participant" type="ParticipantDef" minOccurs="2" maxOccurs="11"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="CreationTime" type="xsd:dateTime">
				<xsd:annotation>
					<xsd:documentation>Date and time of message creation.</xsd:documentation>
					<xsd:documentation>Format : 1999-05-31T13:20:00</xsd:documentation>
					<xsd:documentation xml:lang="EN">Use local time. Value will be read &quot;as it is&quot;. Please do not send an offset from the UTC.</xsd:documentation>
				</xsd:annotation>
			</xsd:element>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="ContactDef">
		<xsd:sequence>
			<xsd:element name="Name">
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:minLength value="1"/>
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Phone" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>plain text without validation. Either phone number or e-mail address must be filled if the user-element is transmitted.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Email" minOccurs="0">
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:maxLength value="70"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="BusinessUnit" type="BusinessUnitDef" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="MessageMetaInfoDef">
		<xsd:annotation>
			<xsd:documentation xml:lang="EN">Meta information for each message.</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="Contact" type="ContactDef" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="MetaInfoDef">
		<xsd:annotation>
			<xsd:documentation>Contains information concerning transaction type, communication parties etc.</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="Transaction" type="TransactionDef">
				<xsd:annotation>
					<xsd:documentation>Specifies the transaction type (GM01, AB01 etc.). Only one transaction per file is allowed. Different types must be sent in separate files.</xsd:documentation>
				</xsd:annotation>
			</xsd:element>
			<xsd:element name="Application" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>Name of the application that built the message.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Communication" type="CommunicationDef"/>
		</xsd:sequence>
		<xsd:attribute name="ExchangeNumber" use="required">
			<xsd:annotation>
				<xsd:documentation xml:lang="EN">unique reference per physical xml-file</xsd:documentation>
			</xsd:annotation>
			<xsd:simpleType>
				<xsd:restriction base="xsd:string">
					<xsd:minLength value="1"/>
					<xsd:maxLength value="14"/>
				</xsd:restriction>
			</xsd:simpleType>
		</xsd:attribute>
		<xsd:attribute name="Test" type="xsd:boolean" use="optional" default="0">
			<xsd:annotation>
				<xsd:documentation>0 - false (default);</xsd:documentation>
				<xsd:documentation>1- true; transmission for test purpose</xsd:documentation>
			</xsd:annotation>
		</xsd:attribute>
		<xsd:attribute name="Count" type="xsd:positiveInteger">
			<xsd:annotation>
				<xsd:documentation>Number of messages (elements) that are collected in the transmitted file.</xsd:documentation>
			</xsd:annotation>
		</xsd:attribute>
	</xsd:complexType>
	<xsd:simpleType name="ParticipantCode">
		<xsd:annotation>
			<xsd:documentation xml:lang="EN">Code identifying the participant</xsd:documentation>
		</xsd:annotation>
		<xsd:restriction base="xsd:string">
			<xsd:minLength value="1"/>
			<xsd:maxLength value="17"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:complexType name="ParticipantCodeDef">
		<xsd:simpleContent>
			<xsd:extension base="ParticipantCode">
				<xsd:attribute name="Alias" use="optional" default="DAK">
					<xsd:annotation>
						<xsd:documentation>Alias code. Describes how the participant is identified in a system, e.g. DAK as DAKOSY-code. Other identifiers are not specified yet.</xsd:documentation>
					</xsd:annotation>
					<xsd:simpleType>
						<xsd:restriction base="xsd:token">
							<xsd:minLength value="1"/>
							<xsd:maxLength value="17"/>
						</xsd:restriction>
					</xsd:simpleType>
				</xsd:attribute>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="ParticipantDef">
		<xsd:sequence>
			<xsd:element name="Code" type="ParticipantCodeDef" maxOccurs="unbounded">
				<xsd:annotation>
					<xsd:documentation xml:lang="EN">Code identifying the participant</xsd:documentation>
				</xsd:annotation>
			</xsd:element>
			<xsd:element name="Name" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>just for informal use</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Pwd" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>Needs only to be set if required by the specified role.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:minLength value="1"/>
						<xsd:maxLength value="17"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
		</xsd:sequence>
		<xsd:attribute name="Role" use="required">
			<xsd:annotation>
				<xsd:documentation xml:lang="EN">Desribes the particpant's communication part as the message's sender, it's recipient etc.</xsd:documentation>
				<xsd:documentation xml:lang="EN">Required entries:</xsd:documentation>
				<xsd:documentation xml:lang="EN">RECIPIENT</xsd:documentation>
				<xsd:documentation xml:lang="EN">SENDER</xsd:documentation>
				<xsd:documentation xml:lang="EN">EDI_PROVIDER</xsd:documentation>
			</xsd:annotation>
			<xsd:simpleType>
				<xsd:restriction base="xsd:string">
					<xsd:minLength value="1"/>
					<xsd:maxLength value="17"/>
				</xsd:restriction>
			</xsd:simpleType>
		</xsd:attribute>
	</xsd:complexType>
	<xsd:complexType name="TransactionDef">
		<xsd:sequence>
			<xsd:element name="Descr" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation xml:lang="EN"/>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:minLength value="1"/>
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
			<xsd:element name="Provider" minOccurs="0">
				<xsd:annotation>
					<xsd:documentation>name of the party who is responsible for the underlying scheme.</xsd:documentation>
				</xsd:annotation>
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:minLength value="1"/>
						<xsd:maxLength value="35"/>
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:element>
		</xsd:sequence>
		<xsd:attribute name="Code" use="required">
			<xsd:annotation>
				<xsd:documentation>Code defined by the provider for the specified transaction.</xsd:documentation>
			</xsd:annotation>
			<xsd:simpleType>
				<xsd:restriction base="xsd:string">
					<xsd:minLength value="1"/>
					<xsd:maxLength value="17"/>
				</xsd:restriction>
			</xsd:simpleType>
		</xsd:attribute>
		<xsd:attribute name="Type" use="required">
			<xsd:annotation>
				<xsd:documentation>Single type which is represented by this file.</xsd:documentation>
				<xsd:documentation>A Transaction identified by its code may contain several types identified by their  type.</xsd:documentation>
				<xsd:documentation>This hierarchy is known from EDIFACT-messages where e. g. the transaction GM01 (code) consists of CUSCAR and APERAK (type).</xsd:documentation>
			</xsd:annotation>
			<xsd:simpleType>
				<xsd:restriction base="xsd:string">
					<xsd:minLength value="1"/>
					<xsd:maxLength value="17"/>
				</xsd:restriction>
			</xsd:simpleType>
		</xsd:attribute>
		<xsd:attribute name="Version" use="required">
			<xsd:annotation>
				<xsd:documentation>Version of message definition</xsd:documentation>
			</xsd:annotation>
			<xsd:simpleType>
				<xsd:restriction base="xsd:string">
					<xsd:minLength value="1"/>
					<xsd:maxLength value="17"/>
				</xsd:restriction>
			</xsd:simpleType>
		</xsd:attribute>
	</xsd:complexType>
</xsd:schema>
